//
//  YkColor.h
//  mcf
//
//  Created by yuike6 yuike6 on 12-1-5.
//  Copyright (c) 2012年 yuike. All rights reserved.
//

#ifndef mcf_YkColor_h
#define mcf_YkColor_h

#import <UIKit/UIKit.h>

#define	RGB_MAX_VALUE	255.0f

#define HSVCOLOR(h,s,v) [UIColor colorWithHue:(h) saturation:(s) value:(v) alpha:1]
#define HSVACOLOR(h,s,v,a) [UIColor colorWithHue:(h) saturation:(s) value:(v) alpha:(a)]

#define RGBA(r, g, b, a) [UIColor colorWithRed:(r)/RGB_MAX_VALUE	\
                                            green:(g)/RGB_MAX_VALUE	\
                                            blue:(b)/RGB_MAX_VALUE	\
                                            alpha:(a)]
#define RGB(r,g,b) RGBA(r, g, b, 1)


#define COLOR_RANDOM    RGB([YMath getRandomNumber:0 to:255], [YMath getRandomNumber:0 to:255], [YMath getRandomNumber:0 to:255])
#define	COLOR_RED		[UIColor redColor]
#define	COLOR_GREEN		[UIColor greenColor]

#define	COLOR_BLUE		[UIColor blueColor]
#define	COLOR_BLACK		[UIColor blackColor]

#define	COLOR_WHITE		[UIColor whiteColor]
#define COLOR_ORANGE    [UIColor orangeColor]

#define COLOR_GRAY      [UIColor grayColor]
#define COLOR_DARKGRAY  [UIColor darkGrayColor]

#define COLOR_MAGENTA   [UIColor magentaColor]
#define COLOR_BROWN     [UIColor brownColor]

#define COLOR_PURPLE    [UIColor purpleColor]
#define COLOR_CYAN      [UIColor cyanColor]

#define COLOR_YELLOW    [UIColor yellowColor]
#define COLOR_LIGHTGRAY [UIColor lightGrayColor]

// 透明颜色
#define	COLOR_CLEAR		[UIColor clearColor]

#define COLOR_SCROLLVIEWTEXTUREDBACKGROUND  [UIColor scrollViewTexturedBackgroundColor]
#define COLOR_VIEWFLIPSIDEBACKGROUND        [UIColor viewFlipsideBackgroundColor]

#endif
